package com.owc.common.lock;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

@Target({ElementType.METHOD, ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
public @interface ULock {

    /**
     * Automatically unlock max time.
     */
    long maxTimeout() default 20L;

    /**
     * Max await fetch lock time.
     */
    long awaitTimeout() default 20L;

    /**
     * Lock key.Default used current login userId
     */
    String lockKey() default "";


}
